package com.jike.noobmoney.adapter;


import android.content.Context;
import android.text.Html;
import android.widget.TextView;

import com.jike.noobmoney.R;
import com.jike.noobmoney.entity.QuestionEntity;


/**
 * Created by kekex on 2018/9/8.
 * 首页Performer的列表adapter
 */

public class QuestionListAdapter extends BaseRecyclerAdapter<QuestionEntity.QuestionBean> {


    private Context context;

    public QuestionListAdapter(Context context) {

        super(R.layout.item_question_list);
        this.context = context;

    }

    @Override
    protected void onBindViewHolder(SmartViewHolder holder, QuestionEntity.QuestionBean item, int position) {

        TextView question = (TextView) holder.findViewById(R.id.tv_question);
        TextView answer = (TextView) holder.findViewById(R.id.tv_answer);

        question.setText("问:" + item.getQuestion());
        answer.setText(Html.fromHtml(item.getAnswer()));


    }
}
